﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.IO;


namespace DAO
{
    public class MySqlConnection
    {
        public static string myPath=string.Empty;
        public static string Connection()
        {
            
            //return "Data Source=KEVINTAN-PC;Initial Catalog=ManagerFile;User ID=sa;Password=123456";
            if (myPath == "")
            {
                TextReader file = new StreamReader(@"..\..\ConnectionString.txt");
                string connect = file.ReadLine();
                file.Close();
                return connect;
            }
            else
            {
                TextReader file = new StreamReader(myPath);
                string connect = file.ReadLine();
                file.Close();
                return connect;
            }
         

        }
    }
}
